package com.catena.core.chain;

import com.catena.core.NodeParameter;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.Map;

/**
 * Created by hx-pc on 16-4-1.
 */
public interface CatenaOperationNodeStart {

    /**
     * 请传入需要存储的map参数集合
     *
     * @param map
     */
    void start(Map<String, Object> map);

    void start();

    void start(NodeParameter parameter);

    void startReturnAll(Map<String, Object> map, HttpServletResponse response);

    void startReturnAll(HttpServletResponse response);

    void startReturnData(Map<String, Object> map, HttpServletResponse response);

    void startReturnData(HttpServletResponse response);

    void startReturnDataWithString(HttpServletRequest servletRequest, HttpServletResponse response);

    void startReturnDataWithObject(HttpServletRequest servletRequest, HttpServletResponse servletResponse);

    void startForward(Map<String, Object> map, HttpServletRequest servletRequest, HttpServletResponse servletResponse, String target);

    void startForward(HttpServletRequest servletRequest, HttpServletResponse servletResponse, String target);

    void startRedirect(Map<String, Object> map, HttpServletResponse servletResponse, String target);

    void startRedirect(HttpServletResponse servletResponse, String target);
}
